﻿ <%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Excel_Compare.aspx.cs" Inherits="FileConverter.BOMCompare.Excel_Compare" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="server">
    <section class="featured" style="font-family: 微软雅黑" >
        <div class="content-wrapper">
            <hgroup class="title">
                <h1><%: Title %>.</h1>
                <h2>共振文件格式转换</h2>
            </hgroup>
            <p>
               共振文件转换标准输入、输出文件格式 <a href="../Help/3000833_PARTS LIST.xlsx">BOM_1_原始文件</a>&nbsp;
                                    <a href="../Help/V3R3-3000833_PARTS LIST2.xlsx">BOM_2_原始文件</a>&nbsp;
            </p>
        </div>
    </section>    
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">

    <script>
        if (document.addEventListener) {
            document.addEventListener('DOMMouseScroll', scrollFunc, false);
        }//W3C    
        window.onmousewheel = document.onmousewheel = scrollFunc;//IE/Opera/Chrome 
        var scrollFunc = function () {

        }
    </script>

    <asp:FileUpload ID="Excel_1" runat="server" />
    <asp:Label ID="Label_Excel_1" runat="server" Text="Label" style="display:none"></asp:Label>
    <asp:FileUpload ID="Excel_2" runat="server" />
    <asp:Label ID="Label_Excel_2" runat="server" Text="Label" style="display:none"></asp:Label>
    <asp:Button ID="Compare" runat="server" Text="Compare" OnClick="Compare_Click" />
    <asp:Button ID="Download" runat="server" Text="Download" OnClick="Download_Click" />
    <section style="height:550px" onmousewheel="return false;">
        <div ID="Div_Scroll" style="width:4%; height:490px; float:left; overflow-x:hidden ; overflow-y:hidden" onscroll="document.getElementById('Div_Excel_2').scrollTop = this.scrollTop;">
            <asp:GridView ID="GridScroll" runat="server" ForeColor="#333333" GridLines="None" AutoGenerateColumns="False" RowStyle-Wrap="false" onrowdatabound="GridView_RowDataBound" >
                <AlternatingRowStyle BackColor="White" />
                <Columns>
                    <asp:TemplateField HeaderText="NO.">
                        <ItemTemplate>
                            <Span><%# Container.DataItem %></Span>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <EditRowStyle BackColor="#2461BF" />
                <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />

<RowStyle Wrap="False" BackColor="#EFF3FB"></RowStyle>
                <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                <SortedAscendingCellStyle BackColor="#F5F7FB" />
                <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                <SortedDescendingCellStyle BackColor="#E9EBEF" />
                <SortedDescendingHeaderStyle BackColor="#4870BE" />
            </asp:GridView>
        </div>
        <div style="width:3px; height:500px; background-color:black; float:left"></div>
        <div ID="Div_Excel_1" style="width:47%; height:500px; float:left; overflow-x:auto; overflow-y:hidden" onscroll="document.getElementById('Div_Excel_2').scrollLeft = this.scrollLeft; document.getElementById('Div_Scroll').scrollTop = this.scrollTop;">
            <asp:GridView ID="GridView_Excel_1" runat="server" ForeColor="#333333" GridLines="None" AutoGenerateColumns="false" RowStyle-Wrap="false">
                <AlternatingRowStyle BackColor="White" />
                <Columns>
                    <%--<asp:TemplateField HeaderText="Quantity">
                        <ItemTemplate>
                            <Span><%#((System.Data.DataRowView)Container.DataItem)["Quantity"]%></Span>
                        </ItemTemplate>
                    </asp:TemplateField>--%>
                    <asp:BoundField DataField="Quantity" HeaderText="Quantity"/>
                    <asp:BoundField DataField="Populate" HeaderText="Populate"/>
                    <asp:BoundField DataField="Designator" HeaderText="Designator"/>
                    <asp:BoundField DataField="Description" HeaderText="Description"/>
                    <asp:BoundField DataField="Footprint" HeaderText="Footprint"/>
                    <asp:BoundField DataField="Manufacturer" HeaderText="Manufacturer"/>
                    <asp:BoundField DataField="Manufacturer-No." HeaderText="Manufacturer-No."/>
                </Columns>
                <EditRowStyle BackColor="#2461BF" />
                <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />

<RowStyle Wrap="False" BackColor="#EFF3FB"></RowStyle>
                <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                <SortedAscendingCellStyle BackColor="#F5F7FB" />
                <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                <SortedDescendingCellStyle BackColor="#E9EBEF" />
                <SortedDescendingHeaderStyle BackColor="#4870BE" />
            </asp:GridView>
        </div>
        <div ID="Div_Excel_2" style="width:48.3%; height:500px; float:right; overflow-x:auto; overflow-y:auto"  onscroll="document.getElementById('Div_Excel_1').scrollLeft = this.scrollLeft; document.getElementById('Div_Excel_1').scrollTop = this.scrollTop;">
            <asp:GridView ID="GridView_Excel_2" runat="server" ForeColor="#333333" GridLines="None" AutoGenerateColumns="false" RowStyle-Wrap="false" >
                <AlternatingRowStyle BackColor="White" />
                <Columns>
                    <%--<asp:TemplateField HeaderText="Quantity">
                        <ItemTemplate>
                            <Span><%#((System.Data.DataRowView)Container.DataItem)["Quantity"]%></Span>
                        </ItemTemplate>
                    </asp:TemplateField>--%>
                    <asp:BoundField DataField="Quantity" HeaderText="Quantity"/>
                    <asp:BoundField DataField="Populate" HeaderText="Populate"/>
                    <asp:BoundField DataField="Designator" HeaderText="Designator"/>
                    <asp:BoundField DataField="Description" HeaderText="Description"/>
                    <asp:BoundField DataField="Footprint" HeaderText="Footprint"/>
                    <asp:BoundField DataField="Manufacturer" HeaderText="Manufacturer"/>
                    <asp:BoundField DataField="Manufacturer-No." HeaderText="Manufacturer-No."/>
                </Columns>
                <EditRowStyle BackColor="#2461BF" />
                <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />

<RowStyle Wrap="False" BackColor="#EFF3FB"></RowStyle>
                <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                <SortedAscendingCellStyle BackColor="#F5F7FB" />
                <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                <SortedDescendingCellStyle BackColor="#E9EBEF" />
                <SortedDescendingHeaderStyle BackColor="#4870BE" />
            </asp:GridView>
        </div>
            <div style="width:3px; height:500px; background-color:black; float:left"></div>
    </section>
    <footer id="container" runat="server">
        <asp:Label ID="lblInfo" runat="server" Text="信息提示" Font-Size="Large" ForeColor="#FF0066"></asp:Label>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    </footer>
</asp:Content>

